package com.train.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 文件模版下载统一管理
 */
@Getter
@AllArgsConstructor
public enum TplFileEnum {

    EMPLOYEE_TPL("1", "/template/员工导入模版.xlsx"),
    STUDENT_TPL("2", "/template/学员导入模版.xlsx");

    private String code;
    private String filePath;

    public static String getFilename(String code) {
        for (TplFileEnum value : values()) {
            if (value.getCode().equals(code)) {
                return value.getFilePath();
            }
        }
        return "";
    }

}
